#ifndef CAUTHINFO_H
#define CAUTHINFO_H

#include <QObject>

class CAuthInfoData
{
public:
    QString networkId,
            host,
            domain,
            resource,
            user,
            password;
    int     port;
};

class CAuthInfo : public QObject
{
    Q_OBJECT
public:
    CAuthInfo(const CAuthInfo &other);
    bool operator !=(const CAuthInfo &other);
    bool operator ==(const CAuthInfo &other);
    explicit CAuthInfo(QObject *parent = 0);

    QString networkId() const;
    void setNetworkId(const QString &id);

    QString host() const;
    void setHost(const QString &host);

    QString domain() const;
    void setDomain(const QString &domain);

    QString resource() const;
    void setResource(const QString &resource);

    QString user() const;
    void setUser(const QString &user);

    QString password() const;
    void setPassword(const QString &password);

    int port() const;
    void setPort(int port);

    static inline bool compare(const CAuthInfo &first, const CAuthInfo &second);
private:
    CAuthInfoData d;
};

#endif // CAUTHINFO_H
